/* This program is used to test the information theory library
   The main part tests the fundamental methods to check that they are working */

#include <iostream>
#include "word32.h"
#include "word64.h"
#include "BitVector32.h"
using namespace std;

extern int test_word32();
extern int test_word64();
extern bool test_BV32();
extern bool test_lfsr32();

int main(){
  // print welcome message
  cout <<  "Main test of FredrikJ71-InformationTheory Lib\n";
  bool totalResult=true;
  
  //start to test the class word32
  bool status=test_word32();
  if(!status)
    totalResult=false;
  cout << "Result from testing word32: " << status << endl;
  
  //test the class word64
  status=test_word64();
  if(!status)
    totalResult=false;
  cout << "Result from testing word64: " << status << endl;
  
  //test the class BitVector32
  status=test_BV32();
  if(!status)
    totalResult=false;
  cout << "Result from testing BitVector32: " << status << endl;

  //test the class lfsr32
  status=test_lfsr32();
  if(!status)
    totalResult=false;
  cout << "Result from testing lfsr32: " << status << endl;
  
  //print final result
  cout << "Result from all the tests: " << totalResult << endl;
}


